'''
Author: admin@attacker.club
Date: 2022-07-14 19:37:09
LastEditTime: 2022-07-14 20:39:36
Description: 
'''


from collections import Counter
host_list=['prod-gateway.c5game.com','trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com', 'trade-api.c5game.com']



domian_dict = {
    'trade-api.c5game.com': 14,
     'inventory.c5game.com': 3, 
     'prod-gateway.c5game.com': 1
     }

# print(domian_dict)
ret = "".join(['"{0} {1}条"\n'.format(x,y) for x,y in domian_dict.items()])
print(ret)


# host = Counter(host_list)
# print(host)

# for x,y in host.items():
#     print(x,y)




     # >接口数量：<font color="warning">{len(ret_add)}</font>


   
            ## 企业微信推送消息
            wxkey = WXWork_CONFIG['test']['key']
            data = f'''
            ## **慢接口统计** 
            >接口数量：<font color="warning">{len(ret_add)}</font>

            >阈值：<font color="info">采集{queryTime}小时内,响应耗时1m的接口</font>
            # '''
            # print(host_results)
            # sms = WXWork_SMS(data,wxkey)    
            # sms.send_msg_markdown()
    